// default package
// Generated 28 Jul, 2014 8:04:07 PM by Hibernate Tools 3.4.0.CR1
package com.galaxy.bean;

import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToOne;
import javax.persistence.PrimaryKeyJoinColumn;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.persistence.UniqueConstraint;
import org.hibernate.annotations.GenericGenerator;
import org.hibernate.annotations.Parameter;

/**
 * SalesFlatOrderGrid generated by hbm2java
 */
@Entity
@Table(name = "sales_flat_order_grid", catalog = "magento", uniqueConstraints = @UniqueConstraint(columnNames = "increment_id"))
public class SalesFlatOrderGrid implements java.io.Serializable {

	private int entityId;
	private SalesFlatOrder salesFlatOrder;
	private CustomerEntity customerEntity;
	private CoreStore coreStore;
	private String status;
	private String storeName;
	private BigDecimal baseGrandTotal;
	private BigDecimal baseTotalPaid;
	private BigDecimal grandTotal;
	private BigDecimal totalPaid;
	private String incrementId;
	private String baseCurrencyCode;
	private String orderCurrencyCode;
	private String shippingName;
	private String billingName;
	private Date createdAt;
	private Date updatedAt;

	public SalesFlatOrderGrid() {
	}

	public SalesFlatOrderGrid(SalesFlatOrder salesFlatOrder) {
		this.salesFlatOrder = salesFlatOrder;
	}

	public SalesFlatOrderGrid(SalesFlatOrder salesFlatOrder,
			CustomerEntity customerEntity, CoreStore coreStore, String status,
			String storeName, BigDecimal baseGrandTotal,
			BigDecimal baseTotalPaid, BigDecimal grandTotal,
			BigDecimal totalPaid, String incrementId, String baseCurrencyCode,
			String orderCurrencyCode, String shippingName, String billingName,
			Date createdAt, Date updatedAt) {
		this.salesFlatOrder = salesFlatOrder;
		this.customerEntity = customerEntity;
		this.coreStore = coreStore;
		this.status = status;
		this.storeName = storeName;
		this.baseGrandTotal = baseGrandTotal;
		this.baseTotalPaid = baseTotalPaid;
		this.grandTotal = grandTotal;
		this.totalPaid = totalPaid;
		this.incrementId = incrementId;
		this.baseCurrencyCode = baseCurrencyCode;
		this.orderCurrencyCode = orderCurrencyCode;
		this.shippingName = shippingName;
		this.billingName = billingName;
		this.createdAt = createdAt;
		this.updatedAt = updatedAt;
	}

	@GenericGenerator(name = "generator", strategy = "foreign", parameters = @Parameter(name = "property", value = "salesFlatOrder"))
	@Id
	@GeneratedValue(generator = "generator")
	@Column(name = "entity_id", unique = true, nullable = false)
	public int getEntityId() {
		return this.entityId;
	}

	public void setEntityId(int entityId) {
		this.entityId = entityId;
	}

	@OneToOne(fetch = FetchType.LAZY)
	@PrimaryKeyJoinColumn
	public SalesFlatOrder getSalesFlatOrder() {
		return this.salesFlatOrder;
	}

	public void setSalesFlatOrder(SalesFlatOrder salesFlatOrder) {
		this.salesFlatOrder = salesFlatOrder;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "customer_id")
	public CustomerEntity getCustomerEntity() {
		return this.customerEntity;
	}

	public void setCustomerEntity(CustomerEntity customerEntity) {
		this.customerEntity = customerEntity;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "store_id")
	public CoreStore getCoreStore() {
		return this.coreStore;
	}

	public void setCoreStore(CoreStore coreStore) {
		this.coreStore = coreStore;
	}

	@Column(name = "status", length = 32)
	public String getStatus() {
		return this.status;
	}

	public void setStatus(String status) {
		this.status = status;
	}

	@Column(name = "store_name")
	public String getStoreName() {
		return this.storeName;
	}

	public void setStoreName(String storeName) {
		this.storeName = storeName;
	}

	@Column(name = "base_grand_total", precision = 12, scale = 4)
	public BigDecimal getBaseGrandTotal() {
		return this.baseGrandTotal;
	}

	public void setBaseGrandTotal(BigDecimal baseGrandTotal) {
		this.baseGrandTotal = baseGrandTotal;
	}

	@Column(name = "base_total_paid", precision = 12, scale = 4)
	public BigDecimal getBaseTotalPaid() {
		return this.baseTotalPaid;
	}

	public void setBaseTotalPaid(BigDecimal baseTotalPaid) {
		this.baseTotalPaid = baseTotalPaid;
	}

	@Column(name = "grand_total", precision = 12, scale = 4)
	public BigDecimal getGrandTotal() {
		return this.grandTotal;
	}

	public void setGrandTotal(BigDecimal grandTotal) {
		this.grandTotal = grandTotal;
	}

	@Column(name = "total_paid", precision = 12, scale = 4)
	public BigDecimal getTotalPaid() {
		return this.totalPaid;
	}

	public void setTotalPaid(BigDecimal totalPaid) {
		this.totalPaid = totalPaid;
	}

	@Column(name = "increment_id", unique = true, length = 50)
	public String getIncrementId() {
		return this.incrementId;
	}

	public void setIncrementId(String incrementId) {
		this.incrementId = incrementId;
	}

	@Column(name = "base_currency_code", length = 3)
	public String getBaseCurrencyCode() {
		return this.baseCurrencyCode;
	}

	public void setBaseCurrencyCode(String baseCurrencyCode) {
		this.baseCurrencyCode = baseCurrencyCode;
	}

	@Column(name = "order_currency_code")
	public String getOrderCurrencyCode() {
		return this.orderCurrencyCode;
	}

	public void setOrderCurrencyCode(String orderCurrencyCode) {
		this.orderCurrencyCode = orderCurrencyCode;
	}

	@Column(name = "shipping_name")
	public String getShippingName() {
		return this.shippingName;
	}

	public void setShippingName(String shippingName) {
		this.shippingName = shippingName;
	}

	@Column(name = "billing_name")
	public String getBillingName() {
		return this.billingName;
	}

	public void setBillingName(String billingName) {
		this.billingName = billingName;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "created_at", length = 19)
	public Date getCreatedAt() {
		return this.createdAt;
	}

	public void setCreatedAt(Date createdAt) {
		this.createdAt = createdAt;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "updated_at", length = 19)
	public Date getUpdatedAt() {
		return this.updatedAt;
	}

	public void setUpdatedAt(Date updatedAt) {
		this.updatedAt = updatedAt;
	}

}
